package com.atguigu.gulimall.search.entity.vo;

import com.atguigu.entity.to.es.SkuESModel;
import lombok.Data;

import java.util.ArrayList;
import java.util.List;

@Data
public class SearchResultVo {

    //查询到所有商品信息
    private List<SkuESModel> products;

    //分页信息
    private Integer pageNum;//当前页面
    private Long total;//总记录数
    private Integer totalPages;//总页数
    private List<Integer> totalNavs;//页面集合

    //品牌信息
    private List<BrandVo> brands;
    //分类信息
    private List<CatalogVo> catalogs;
    //属性信息
    private List<AttrVo> attrs;
    //面包屑导航
    private List<NavVo> navVos = new ArrayList<>();
    //面包屑被选中的属性id 需要在请求参数中构造
    private List<Long> attrIds = new ArrayList<>();

    @Data
    public static class NavVo{
        private String navName;
        private String navValue;
        private String link;
    }

    @Data
    public static class BrandVo{
        private Long brandId;
        private String brandName;
        private String brandImg;
    }

    @Data
    public static class CatalogVo{
        private Long catalogId;
        private String catalogName;
    }

    @Data
    public static class AttrVo{
        private Long attrId;
        private String attrName;
        private List<String> attrValue;
    }
}
